package com.smartmap;

import android.app.Activity;
import android.content.Intent;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.ImageButton;

import com.utils.SharedPreferencesUtils;

public class BasicActivity extends Activity {
	protected SharedPreferencesUtils sharedPreferencesUtils;

	@Override
	public void startActivity(Intent intent) {
		super.startActivity(intent);
		super.overridePendingTransition(R.anim.push_left_in,
				R.anim.push_right_out);

	}

	@Override
	protected void onResume() {
		super.onResume();
		sharedPreferencesUtils = SharedPreferencesUtils
				.getInstance(BasicActivity.this);
		ImageButton button = (ImageButton) findViewById(R.id.top_back);
		if (button instanceof ImageButton) {
			button.setOnClickListener(new OnClickListener() {

				@Override
				public void onClick(View v) {
					BasicActivity.this.finish();
					overridePendingTransition(R.anim.push_right_in,
							R.anim.push_left_out);
				}
			});
		}
	}

}
